<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div {
            width: 300px;
            height: 300px;
            background-color: blanchedalmond;
        }
        div::before{
            content: "no way";
            width: 50px;
            height: 50px;
            background-color: rgb(59, 213, 161);
            display: block;
            /* 可设置宽高,独占一行 */
        }
        div::after{
            content: "你再看看你后面呢";
            width: 50px;
            height: 80px;
            background-color: rgb(76, 173, 214);
            display: block;

        }
    </style>
</head>
<body>
    <div>你看看你后面呢</div>
</body>
</html>